home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / rpgedi1a / clshero.cls < prev    next >
Text File  |  1999-09-15  |  2KB  |  53 lines

  1. VERSION 1.0 CLASS
  2. BEGIN
  3.   MultiUse = -1  'True
  4.   Persistable = 0  'NotPersistable
  5.   DataBindingBehavior = 0  'vbNone
  6.   DataSourceBehavior  = 0  'vbNone
  7.   MTSTransactionMode  = 0  'NotAnMTSObject
  8. END
  9. Attribute VB_Name = "clsHero"
  10. Attribute VB_GlobalNameSpace = False
  11. Attribute VB_Creatable = True
  12. Attribute VB_PredeclaredId = False
  13. Attribute VB_Exposed = False
  14. 'this class is for describing the hero
  15.  
  16. 'private member variables
  17. Public itsClass As Integer      'the hero's character class (Mage, Warrior, etc.)
  18. Public itsRace As Integer       'the hero's race (Elf, Human, Dwarf etc.)
  19. Public itsName As String        'the hero's name
  20. Public itsHP As Integer         'the hero's hit points
  21. Public itsMP As Integer         'the hero's magic points
  22. Public itsExperience As Integer   'the hero's current experience points
  23. Public itsLevel As Integer        'the hero's current level
  24. Public itsNextLevel As Integer    'the experience needed to reach the next level
  25. Public itsIntelligence As Integer 'the hero's intelligence
  26. Dim itsBaseStats(0 To 4) As Integer 'the hero's base stats
  27. Dim itsCurStats(0 To 4) As Integer  'the hero's current stats
  28. Dim itsGold As Double               'holds the hero's gold
  29. 'Dim itsInventory(0 To 20) As New clsItmes      'the hero's inventory
  30. Dim MaxItems As Integer         'holds the maximum inventory items
  31. Dim itsWieght As Integer        'holds the character's current weight
  32. Dim itsMaxWeight As Integer     'holds the character's current maximum wieght
  33. Dim itsHeight As Integer        'holds the character's height
  34.  
  35.  
  36. 'for accessing the arrays of stats
  37. Public Function setBaseStat(stat As Integer, value As Integer)
  38.     itsBaseStats(stat) = value
  39. End Function
  40.  
  41. Public Function getBaseStat(stat As Integer) As Integer
  42.     getBaseStat = itsBaseStats(stat)
  43. End Function
  44.  
  45. Public Function setCurStat(stat As Integer, value As Integer)
  46.     itsCurStats(stat) = value
  47. End Function
  48.  
  49. Public Function getCurStat(stat As Integer) As Integer
  50.     getCurStat = itsCurStats(stat)
  51. End Function
  52.  
  53.